feat(model): add dummy text encoder for constraint-only generation#11
Open
Lee-Jun-Hyuk-37 wants to merge 1 commit intonv-tlabs:mainfrom
Open
feat(model): add dummy text encoder for constraint-only generation#11Lee-Jun-Hyuk-37 wants to merge 1 commit intonv-tlabs:mainfrom
Lee-Jun-Hyuk-37 wants to merge 1 commit intonv-tlabs:mainfrom
Conversation
Add TEXT_ENCODER_MODE=dummy option that replaces the LLM2Vec text encoder with a zero-vector encoder, enabling constraint-only motion generation without loading Llama-3-8B weights. This addresses two limitations: - Users without Meta Llama access can still use Kimodo with kinematic constraints (keyframes, end-effectors, root paths) - VRAM requirement drops from ~17GB to ~1.1GB, making Kimodo usable on consumer GPUs (e.g. 8-12GB) Usage: TEXT_ENCODER_MODE=dummy kimodo_gen "" --constraints path.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First of all, thank you for building and open-sourcing Kimodo. It is a great project.
Summary
TEXT_ENCODER_MODE=dummyoption that replaces the LLM2Vec text encoder with a zero-vector encoderMotivation
Some use cases only need kinematic constraints to control motion generation, without any text prompts. For example, robotics pipelines or animation workflows that already have precise keyframe/end-effector targets do not benefit from text conditioning.
Currently there is no way to skip the text encoder. Even with an empty prompt, Kimodo always loads the full Llama-3-8B model (~17GB VRAM). This change adds a lightweight
DummyTextEncoderthat returns zero embeddings (equivalent to the unconditional case in classifier-free guidance training), so the diffusion model can run with constraints alone.As a side benefit, this also helps users who cannot load the text encoder due to VRAM limitations (<17GB) or pending Meta Llama gated repo approval.
Usage
TEXT_ENCODER_MODE=dummy kimodo_gen "" --constraints constraints.json --output motion